const { get, post } = require('./http')
const prefix = 'ScoringMatches'

// 球童登录
export const caddieLogin = (params) => { return post(`${prefix}/login`, params) }
// 球童二维码生成
export const caddieQrcode = (params) => { return post(`${prefix}/caddiecode`, params, 'arraybuffer') }
// 获取成绩数据
export const getScoring = (params) => { return post(`${prefix}/getScoringgroup`, params) }
// 录入分数接口
export const addScore = (params) => { return post(`${prefix}/addscore`, params) }

// 录入分数接口
export const deleteScore = (params) => { return post(`${prefix}/deleteScore`, params) }

// 技术统计
export const addStatistics = (params) => { return post(`${prefix}/addstatistics`, params) }
// 个人数据统计
export const moreStatistics = (params) => { return post(`${prefix}/morestatistics`, params) }
// 个人成绩卡
export const getScoreCard = (params) => { return post(`${prefix}/score`, params) }
// 赛事球员排名
export const getRankList = (params) => { return post(`${prefix}/ranklist`, params) }

/** 球局球童 */
export const caddieGameQrcode = (params) => { return post(`${prefix}/caddiegames`, params, 'arraybuffer') }


export const addGameScore = (params) => { return post(`PersonalMatches/addscore`, params) }
export const getGameScoring = (params) => { return post(`PersonalMatches/getpersonalmatches_scoresbycaddie`, params) }
export const deleteGameScore = (params) => { return post(`PersonalMatches/deletescore`, params) } // 设置分数


